<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8">
		<meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=no" />
		<title></title>
		<script src="js/axios.min.js" type="text/javascript" charset="utf-8"></script>
		<script src="js/rem.js" type="text/javascript" charset="utf-8"></script>
		<link rel="stylesheet" type="text/css" href="css/userComplete.css"/>
		<link rel="stylesheet" type="text/css" href="fonts/iconfont.css"/>
		<style type="text/css">
			input{
				position: absolute;
				top: .3rem;
				left: 1.2rem;
				height: 0.5rem;
				width: 5rem;
				border: ;
			}
			
			.sure{
				margin-left: 2rem;
				font-size: 0.28rem
			}
			
		</style>
	</head>
	<body>
		<script type="text/javascript">
			window.onload=function(){
				let token=localStorage.getItem('token')
				let sure=document.querySelector('.sure')
			let ipts=document.querySelectorAll('input')
			sure.onclick=function(){
				let username=ipts[0].value
				let userImgUrl=ipts[1].value
				//修改用户信息
				let updateUserApi='http://15637237221.wicp.vip/yh/mine/updateUserInformation.do'
				axios.post(updateUserApi,{
					token,
					username,
					userImgUrl,
				}).then(res=>{
					console.log(res)
					history.back()
					
				})
			}
			}
			
		</script>
		<div class="con">
			<header>
				<img src="img/tou.gif">
				<p><a href="userComplete.html" class="iconfont icon-left"> <a><span>修改信息</span><a href="javascript:;" class="sure">保存</a></p>
			</header>
			<main>
				<ul>
					<li style="display: block;">
						用户名:<input type="" name="" id="" value="" /> 
					</li>
					<li style="display: block;">
						头像: <input type="" name="" id="" value="" /> 
					</li>
				</ul>
			</main>
		</div>
	</body>
</html>
